<template>
  <a-layout>
    <div>
      <a class="titleStyle">[Logo]储能工程经济评价软件</a>
    </div>
    <a-layout-header class="header">
      <div class="logo" />
      <a-menu
        v-model:selectedKeys="selectedKeys1"
        theme="dark"   
        mode="horizontal"
        :style="{ lineHeight: '64px'}"
      >
        <a-menu-item key="1">新建工程</a-menu-item>
        <a-menu-item key="2">打开工程</a-menu-item>
        <a-menu-item key="3">保存</a-menu-item>
        <a-menu-item key="4">另存为</a-menu-item>
        <a-menu-item key="5">关闭工程</a-menu-item>
        <a-menu-item key="6">计算基本方案</a-menu-item>
        <a-menu-item key="7">敏感性分析</a-menu-item>
        <a-menu-item key="8">试算建设投资/产量/售价</a-menu-item>
        <a-menu-item key="9">设置电价补贴参数</a-menu-item>
        <a-menu-item key="10">计算器</a-menu-item>
        <a-menu-item key="11">方案比选</a-menu-item>
        <a-menu-item key="12">设置报表参数</a-menu-item>
        <a-menu-item key="13">导出到Excel</a-menu-item>
        <a-menu-item key="14">导出到Word</a-menu-item>
        <a-menu-item key="15">导出图表</a-menu-item>
        <a-menu-item key="16">设置节能减排参数</a-menu-item>
        <a-menu-item key="17">生成评价报告</a-menu-item>
        <a-menu-item key="18">帮助</a-menu-item>
        <a-menu-item key="19">关于</a-menu-item>
      </a-menu>
    </a-layout-header>
    <a-layout>
      <a-layout-sider width="200" style="background: #fff">
        <a-menu
          v-model:selectedKeys="selectedKeys2"
          v-model:openKeys="openKeys"
          mode="inline"
          :style="{ height: '100%', borderRight: 0 }"
        >
          <a-sub-menu key="sub1">
            <template #title>
              <span>
                <database-outlined />
                基础数据
              </span>
            </template>
            <a-menu-item key="1"><router-link to="baseparameter">基本参数</router-link></a-menu-item>
            <a-menu-item key="2"><router-link to="sourcesoffund">资金来源</router-link></a-menu-item>
            <a-menu-item key="3"><router-link to="cost">成本费用</router-link></a-menu-item>
            <a-menu-item key="4"><router-link to="incomeandtaxes">收入和税金</router-link></a-menu-item>
          </a-sub-menu>
          <a-sub-menu key="sub2">
            <template #title>
              <span>
                <table-outlined />
                报表
              </span>
            </template>
            <a-menu-item key="5">01目标企业账面价值表</a-menu-item>
            <a-menu-item key="6">02收购发生前目标企业绩效指标表</a-menu-item>
            <a-menu-item key="7">03目标企业净现金流量预测表</a-menu-item>
            <a-menu-item key="8">04总成本费用估算表</a-menu-item>
            <a-menu-item key="9">05资产折旧摊销估算表</a-menu-item>
            <a-menu-item key="10">06利润与利润分配表</a-menu-item>
            <a-menu-item key="11">07借款还本付息计划表</a-menu-item>
            <a-menu-item key="12">08财务计划现金流量表</a-menu-item>
            <a-menu-item key="13">09项目投资现金流量表</a-menu-item>
            <a-menu-item key="14">10项目资本金现金流量表</a-menu-item>
            <a-menu-item key="15">11投资各方现金流量表</a-menu-item>
            <a-menu-item key="16">12资产负债表</a-menu-item>
            <a-menu-item key="17">13财务指标汇总表</a-menu-item>
          </a-sub-menu>
          <a-sub-menu key="sub3">
            <template #title>
              <span>
                <calculator-outlined /> 
                EVA测算表
              </span>
            </template>
            <a-menu-item key="18">14EVA测算表</a-menu-item>
          </a-sub-menu>
          <a-sub-menu key="sub4">
            <template #title>
              <span>
                <file-search-outlined />
                敏感性分析
              </span>
            </template>
            <a-menu-item key="9">敏感性参数</a-menu-item>
            <a-menu-item key="10">15敏感性分析表</a-menu-item>
            <a-menu-item key="11">16敏感度系数和临界点分析表</a-menu-item>
          </a-sub-menu>
          <a-sub-menu key="sub5">
            <template #title>
              <span>
                <bar-chart-outlined />
                图表
              </span>
            </template>
            <a-menu-item key="9">17项目投资财务内部收益率分析图</a-menu-item>
            <a-menu-item key="10">18项目资本金财务内部收益率分析图</a-menu-item>
            <a-menu-item key="11">19项目盈亏平衡分析图</a-menu-item>
          </a-sub-menu>
        </a-menu>
      </a-layout-sider>
      <a-layout style="padding: 0 24px 24px">
        <a-breadcrumb style="margin: 16px 0">
          <!-- <a-breadcrumb-item>Home</a-breadcrumb-item>
          <a-breadcrumb-item>List</a-breadcrumb-item>
          <a-breadcrumb-item>App</a-breadcrumb-item> -->
        </a-breadcrumb>
        <a-layout-content
          :style="{ background: '#fff', padding: '24px', margin: 0, minHeight: '280px' }"
        > 
          <!-- 这里是子路由显示区域。每个vue只能设置一个router-view，App.vue也有一个 -->
          <router-view></router-view>  

        </a-layout-content>
      </a-layout>
    </a-layout>
  </a-layout>
</template>
<script lang="ts">
import {DatabaseOutlined,TableOutlined,CalculatorOutlined,FileSearchOutlined,BarChartOutlined} from '@ant-design/icons-vue';
import { defineComponent, ref } from 'vue';
export default defineComponent({
  components: {
    DatabaseOutlined,
    TableOutlined,
    CalculatorOutlined,
    FileSearchOutlined,
    BarChartOutlined
  },
  setup() {
    return {
      selectedKeys1: ref<string[]>(['2']),
      selectedKeys2: ref<string[]>(['1']),
      collapsed: ref<boolean>(false),
      openKeys: ref<string[]>(['sub1']),
    };
  },
});
</script>
<style>
/* 覆盖antd样式 ------------start------- */
#app{
  /* F12调试前端，覆盖antd的默认样式，以达到自己想要的效果 */
  margin-top: 0px;
}
.ant-layout-header{
  /* 把padding-right,padding-left都由50px改为0px */
    padding-top: 0px;
    padding-right: 0px; 
    padding-bottom: 0px;
    padding-left: 0px;
}
/* 覆盖antd样式 ---------------end---------- */

.titleStyle{
  font-size:30px;
  color:black;
  float:left;
}


/* 设置导航栏的logo */
#components-layout-demo-top-side-2 .logo {
  float: left;
  width: 120px;
  height: 31px;
  margin: 16px 24px 16px 0;
  background: rgba(255, 255, 255, 0.3);
}

/* 设置top导航栏的外边距 */
.ant-row-rtl #components-layout-demo-top-side-2 .logo {
  float: right;
  margin: 16px 0 16px 24px;
}

.site-layout-background {
  background: #fff;
}
</style>
